﻿<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
    <title></title>
</head>
<body>
    <script type="text/javascript">
        window.onload = function () {
            var canvas = document.getElementById("mycanvas");
            var context = canvas.getContext("2d");
            var img = new Image();
            img.onload = function () {
                context.drawImage(img, 10, 10, 400, 300);
            };
            img.src = "greenfield.jpg";
        }
    </script>   
    <canvas id="mycanvas" width="500" height="500" style="border: 1px solid black"></canvas>
</body>
</html>
